<template>
	<view class="container">
		<!-- 		<cu-custom bgColor="bg-blue" :isBack="true">
			<block slot="backText"></block>
			<block slot="content">通用详情页</block>
		</cu-custom> -->

		<view class="bg-top bg-blue">
			<!-- 拼车人员列表 -->
			<view class="center-box shadow">
				<view class="cu-list menu">
					<view class="cu-bar bg-white margin-top-xs u-border-bottom">
						<view class="action sub-title">
							<text class="text-xl text-bold text-blue text-shadow">申请人员</text>
							<text class="text-ABC text-blue">JoinedPpl</text>
						</view>
					</view>
					<view v-if="joinList.length < 1" class="padding text-center text-grey">暂无数据</view>
					<view class="cu-item" style="padding: 0;">
						<view class="content">
							<text class="cuIcon-myfill text-blue"></text>
							<text class="text-lg">凯文童鞋</text>
						</view>
						<view class="action">
							<view  class="cu-tag radius bg-blue light">
								18688881093
							</view>
							<button class="cu-btn round sm shadow bg-green margin-left" @click="sure()">同意</button>
							<button class="cu-btn round sm shadow bg-red margin-left">驳回</button>
						</view>
					</view>
					
					<view class="cu-item" style="padding: 0;" >
						<view class="content">
							<text class="cuIcon-myfill text-blue"></text>
							<text class="text-lg">西安彭于晏</text>
						</view>
						<view class="action">
							<view  class="cu-tag radius bg-blue light">
								13366661323
							</view>
							<button class="cu-btn round sm shadow bg-green margin-left " @click="sure()">同意</button>
							<button class="cu-btn round sm shadow bg-red margin-left" @click="reject()">驳回</button>
						</view>
					</view>

				</view>
			</view>
		<view class="">
			<u-modal :show="show" title='是否同意授权用户?' content='是否同意?' @confirm="confirm" @cancel="cancel" ref="uModal" :showCancelButton = "showCancelButton" :asyncClose="true"></u-modal>
		</view>
		<view class="">
			<u-modal :show="rejectShow" title='驳回申请' content='是否驳回用户审批?' @confirm="confirm2" @cancel="cancel2" ref="uModal" :showCancelButton = "showCancelButton" :asyncClose="true"></u-modal>
		</view>
		<u-toast ref="uToast"></u-toast>
		</view>
	</view>
</template>

<script>
	// import request from '@/common/request.js';
	export default {
		data() {
			return {
				joinList: [{

					},
					{

					}
				],
				form: {
					remark: '需求备注需求备注需求备注需求备注需求备注'
				},
				fileList4: [{
						url: 'https://cdn.uviewui.com/uview/swiper/1.jpg',
					},
					{
						url: 'https://cdn.uviewui.com/uview/swiper/1.jpg',
					},
					{
						url: 'https://cdn.uviewui.com/uview/swiper/1.jpg',
					}
				],
				deletable: false,
				status: '',
				show: false,
				rejectShow:false,
				showCancelButton:true,
				uToastType: {
					type: 'success',
					title: '默认主题',
					message: "操作成功",
					// 	iconUrl: '/pages/kwork/list'
					url: '/pages/kwork/list',
				}
			}
		},
		onShow() {

		},
		onLoad(e) {
			this.status = e.status
		},
		onReachBottom() {

		},
		onShareAppMessage() {
			return {
				title: '分享'
			}
		},
		methods: {
			sure() {
				console.log(1)
				this.show = true;

			},
			reject() {
				console.log(111)
				this.rejectShow = true;
			
			},

			cancel(){
				this.$u.toast('您取消了~')
				
				this.show = false;
			},
			cancel2(){
				this.$u.toast('您取消了~')
				
				this.rejectShow = false;
			},
			confirm2(){
				let uToastType = this.uToastType;				this.rejectShow = false;
				this.$refs.uToast.show({
					...uToastType,
					complete() {
						uToastType.url && uni.navigateTo({
							url: uToastType.url
						})
					}
				})
			
				
			},
			confirm(){
				let uToastType = this.uToastType;
				this.show = false;
				this.$refs.uToast.show({
					...uToastType,
					complete() {
						uToastType.url && uni.navigateTo({
							url: uToastType.url
						})
					}
				})

				
			}
		}
	}
</script>
<style lang="scss" scoped>
	.container {
		width: 750rpx;
		color: #333333;

		.bg-top {
			margin-top: -1rpx;
			width: 750rpx;
			height: 320rpx;
			padding-top: 100rpx;
			border-radius: 0 0 20% 20%;

			.top-box {
				width: 700rpx;
				background-color: #FFFFFF;
				margin: 0 auto;
				border-radius: 20rpx;
				padding: 20rpx 30rpx 0rpx;
				position: relative;

				.qh-pic {
					position: absolute;
					right: 64rpx;
					top: -50rpx;
					border-radius: 12rpx;
				}

				.qh-title {
					width: 100%;
					height: 60rpx;
					line-height: 65rpx;
					text-align: center;
					// 	padding-right: 190rpx;
				}

				.bxBox {
					position: relative;
					display: flex;
					/* padding: 0 30rpx; */
					min-height: 100rpx;
					/* background-color: #ffffff; */
					/* justify-content: space-between; */
					align-items: center;
					font-size: 30rpx;
					line-height: 1.6em;
					flex: 1;

					.bxImg {
						display: inline-block;
						margin-right: 10rpx;
						width: 1.6em;
						text-align: center;
					}
				}

			}
		}

		.center-box {
			color: #333333;
			width: 700rpx;
			background-color: #FFFFFF;
			margin: 0 auto;
			border-radius: 20rpx;
			padding: 0rpx 30rpx 0rpx;
			position: relative;
			margin-top: 20rpx;
		}
	}
</style>